package us.mmapp;

import us.mmapp.util.ApplicationData;
import android.app.Activity;
import android.content.SharedPreferences;

public class LogoutActivity extends Activity {
	@Override
	public void onResume()
	{
		super.onResume();
		// Mark shared preferences
	    SharedPreferences settings = getSharedPreferences("LOGIN", 0);
	    SharedPreferences.Editor editor = settings.edit();
	    editor.putString("username", "");
	    editor.putString("password", "");
	    editor.putBoolean("loggedIn", false);
	    editor.commit();
	    ApplicationData.logOut();
	    // Finish the activity
	    overridePendingTransition(R.anim.fade, R.anim.hold);
	    finish();
	}
}
